package com.studentmanagement.service;

import java.util.List;

import com.studentmanagement.model.Enrollment;
import com.studentmanagement.model.PageBean;

public interface EnrollmentService {

    // 添加选课记录
    boolean addEnrollment(Enrollment enrollment);

    // 更新选课记录
    boolean updateEnrollment(Enrollment enrollment);

    // 删除选课记录
    boolean deleteEnrollment(Integer enrollmentId);

    // 根据ID查询选课记录
    Enrollment getEnrollmentById(Integer enrollmentId);

    // 查询所有选课记录
    List<Enrollment> getAllEnrollments();

    // 分页查询选课记录列表
    PageBean<Enrollment> getEnrollmentsByPage(int pageNum, int pageSize, String sortField, String sortOrder);

    // 根据学生ID查询选课记录
    List<Enrollment> getEnrollmentsByStudentId(Integer studentId);

    // 根据课程ID查询选课记录
    List<Enrollment> getEnrollmentsByCourseId(Integer courseId);
}